package com.yanqu.road.server.cmd.banquet.cross.goodbanquet;

import com.yanqu.road.message.YanQuMessage;
import com.yanqu.road.server.cmd.base.AbstractCommand;
import com.yanqu.road.server.command.Cmd;
import com.yanqu.road.server.gameplayer.GamePlayer;
import com.yanqu.road.server.manger.banquet.CrossBanquetMgr;
import com.yanqu.road.server.protocol.Protocol;

/**
 * @Description
 * @Author cwq
 * @Data 2021/11/10 9:54
 */
@Cmd(code = Protocol.S_CROSS_GOOD_BANQUET_ACTIVITY_EXIT, desc = "离开宴会争霸")
public class CrossBanquetActivityExitCmd extends AbstractCommand {
    @Override
    public boolean parseData(YanQuMessage packet) throws Exception {
        return true;
    }

    @Override
    public void execute(GamePlayer player, YanQuMessage packet) throws Exception {
        if (player == null) {
            return;
        }
        CrossBanquetMgr.removeActivity(player);
    }

    @Override
    public void sendData(GamePlayer player) {

    }
}
